home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-04-25 | 2.7 KB | 101 lines | [TEXT/MPS ] |
- //========================================================================================
- //
- // File: FWPicShp.h
- // Release Version: $ ODF 1 $
- //
- // Copyright: (c) 1993 - 1996 by Apple Computer, Inc., all rights reserved.
- //
- //========================================================================================
-
- #ifndef FWPICSHP_H
- #define FWPICSHP_H
-
- #ifndef FWSHAPE_H
- #include "FWShape.h"
- #endif
-
- #ifndef FWBNDSHP_H
- #include "FWBndShp.h"
- #endif
-
- #ifndef FWPICTUR_H
- #include "FWPictur.h"
- #endif
-
- //========================================================================================
- // Forward Declarations
- //========================================================================================
-
- class FW_CGraphicContext;
- class FW_CBitmapShape;
-
- //========================================================================================
- // class FW_CPictureShape
- //========================================================================================
-
- class FW_CPictureShape : public FW_CBoundedShape
- {
- public:
- FW_DECLARE_CLASS
- FW_DECLARE_AUTO(FW_CPictureShape)
-
- //----------------------------------------------------------------------------------------
- // Constructors/Destructors
- //
- public:
- FW_CPictureShape(FW_CPicture picture, const FW_CRect& dstRect);
-
- FW_CPictureShape(const FW_CPictureShape& other);
- FW_CPictureShape(FW_CReadableStream& stream);
-
- virtual ~ FW_CPictureShape();
-
- //----------------------------------------------------------------------------------------
- // Operators
- //
- public:
- FW_CPictureShape& operator=(const FW_CPictureShape& other);
-
- //---------------------------------------------------------------------------------------
- // Inherited API
- //
- public:
- // ----- Rendering -----
- virtual void Render(FW_CGraphicContext& gc) const;
-
- // ----- Flatten -----
- virtual void Flatten(FW_CWritableStream& stream) const;
-
- //---------------------------------------------------------------------------------------
- // New API
- //
- public:
- // ----- Rendering -----
- static void RenderPicture(FW_CGraphicContext& gc,
- FW_CPicture picture,
- const FW_CRect& dstRect);
-
- // ----- Copying -----
- virtual FW_CShape* Copy() const;
-
- // ----- Archiving -----
- static void* Read(FW_CReadableStream& stream, FW_ClassTypeConstant type);
-
- // ----- Geometry -----
- void SetGeometry(const FW_CPicture& picture, const FW_CRect& dstRect);
- void GetGeometry(FW_CPicture& picture, FW_CRect& dstRect) const;
-
- FW_CPicture GetPicture() const
- {return fPicture;}
- void SetPicture(const FW_CPicture& picture)
- {fPicture = picture;}
-
- //---------------------------------------------------------------------------------------
- // Data Member
- //
- private:
- FW_CPicture fPicture;
- };
-
- #endif
-